package core;

import java.net.MalformedURLException;
import java.net.UnknownHostException;
import java.rmi.RemoteException;

import icore.ICoreLogin;

import javax.jms.JMSException;

import activeQM.productorQMColaServidor;
import contenedorSpring.Contenedor;

/**
 * @author Elkin Torres
 * 
 */
public class CoreLogin implements ICoreLogin {
	/**
	 * 
	 */
	private static final long serialVersionUID = 7082871017925512637L;

	@Override
	public void validarUsuario(String usuario, String password,	String hostAddress) throws JMSException, RemoteException, UnknownHostException, MalformedURLException {		
		//Registros rg = (Registros) Contenedor.getSingleton().getApplicationContext().getBean("registroRMI");
		//rg.registrarControlRemoto();
		productorQMColaServidor qm = (productorQMColaServidor) Contenedor.getSingleton().getApplicationContext().getBean("producerLogin");
		qm.sendMessages(usuario + ";" + password + ";" + hostAddress);
	}
}
